package com.rimi.mapper;

import com.rimi.bean.YqzcGoods;

import java.util.List;

/**
 * @author luka
 * @version V1.0
 * @date 2021 2021/7/5 0005 15:01
 */
public interface ShoppingTrolleyMapper {
    List<YqzcGoods> findAllGoodsInShoppingTrolleyByUserId(Integer userId);

    int addGoodsToShoppingTrolley(Integer trolley,Integer goodId, Integer count);

    int findShoppingTrolleyIdByUserId(Integer userId);

    int deleteGoodsInShoppingTrolleyByUserId(int trolleyId, Integer goodId);

    int updateGoodsInShoppingTrolleyByUserId(int trolleyId, Integer goodId, Integer count);

    int checkGoodIsExist(int trolleyId, Integer goodId);

    int getGoodCountInTrolley(int trolleyId, Integer goodId);
}
